package com.shensi.appCollect.service.impl;

import com.shensi.appCollect.dao.ReductionStationRelationsMapper;
import com.shensi.appCollect.pojo.ReductionStationRelations;
import com.shensi.appCollect.service.ReductionStationRelationsService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * 立减活动和油站关系Service业务层处理
 * 
 * @author qujia
 * @date 2021-11-02
 */
@Service("reductionStationRelationsService")
public class ReductionStationRelationsServiceImpl implements ReductionStationRelationsService
{
    @Resource
    private ReductionStationRelationsMapper reductionStationRelationsMapper;

    /**
     * 查询立减活动和油站关系
     * 
     * @param activityOilId 立减活动和油站关系ID
     * @return 立减活动和油站关系
     */
    @Override
    public ReductionStationRelations selectReductionStationRelationsById(Long activityOilId)
    {
        return reductionStationRelationsMapper.selectReductionStationRelationsById(activityOilId);
    }

    /**
     * 查询立减活动和油站关系列表
     * 
     * @param reductionStationRelations 立减活动和油站关系
     * @return 立减活动和油站关系
     */
    @Override
    public List<ReductionStationRelations> selectReductionStationRelationsList(ReductionStationRelations reductionStationRelations)
    {
        return reductionStationRelationsMapper.selectReductionStationRelationsList(reductionStationRelations);
    }

    /**
     * 新增立减活动和油站关系
     * 
     * @param reductionStationRelations 立减活动和油站关系
     * @return 结果
     */
    @Override
    public int insertReductionStationRelations(ReductionStationRelations reductionStationRelations)
    {
        return reductionStationRelationsMapper.insertReductionStationRelations(reductionStationRelations);
    }

    /**
     * 修改立减活动和油站关系
     * 
     * @param reductionStationRelations 立减活动和油站关系
     * @return 结果
     */
    @Override
    public int updateReductionStationRelations(ReductionStationRelations reductionStationRelations)
    {
        return reductionStationRelationsMapper.updateReductionStationRelations(reductionStationRelations);
    }

    /**
     * 批量删除立减活动和油站关系
     * 
     * @param activityOilIds 需要删除的立减活动和油站关系ID
     * @return 结果
     */
    @Override
    public int deleteReductionStationRelationsByIds(Long[] activityOilIds)
    {
        return reductionStationRelationsMapper.deleteReductionStationRelationsByIds(activityOilIds);
    }

    /**
     * 删除立减活动和油站关系信息
     * 
     * @param activityOilId 立减活动和油站关系ID
     * @return 结果
     */
    @Override
    public int deleteReductionStationRelationsById(Long activityOilId)
    {
        return reductionStationRelationsMapper.deleteReductionStationRelationsById(activityOilId);
    }
}
